<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
    <th:block th:include="include_mobile :: header('居民户籍信息')" />

</head>
<body class="grayw-bg full-height-layout" >

<div class="wrapper1">
    <div th:replace="include_mobile :: top" ></div>
    <div class="container-wrapper">
        <div class="row">
            <ol class="breadcrumb">
                <li><i class="fa fa-map-marker"></i> <a th:href="@{/jjm/shi/mobile}">市</a></li>
                <li><a th:href="@{/jjm/xian/mobile(id=${xianInfo.deptId})}" th:text="${xianInfo.deptName}"></a></li>
                <li><a th:href="@{/jjm/xiang/mobile(id=${xiangInfo.deptId})}" th:text="${xiangInfo.deptName}"></a></li>
            </ol>
        </div>
        <div class="row">
            <div class="col-md-12 select-table table-bordered">
                <div class="btn-group-sm">
                    <a class="btn btn-primary" onclick="$.table.exportExcel()">
                        <i th:text="下载表格"  class="fa fa-download"></i>
                    </a>
                    <label class="col-md-offset-1" th:text="总购洁净煤：+ *{totalAmount==null ? '0' : totalAmount}+吨"></label>
                </div>
                <table id="bootstrap-table"></table>
            </div>
        </div>
        <div class="row" style="padding: 0 10px;">
            <label th:each="dept : ${deptList}" th:value="${dept.deptId}" style="margin:5px">
                <a class="btn btn-success dept-info" th:text="${dept.deptName}" th:href="@{/jjm/village/mobile(id=${dept.deptId})}" ></a>
            </label>

        </div>
    </div>
</div>
<th:block th:include="include_mobile :: footer" />
<script th:inline="javascript">
var prefix = ctx + "jjm/xiang";
var xiangId = [[${xiangId}]];
var exportUrl = prefix + "/export";
if(xiangId){
    exportUrl = exportUrl+"?townId="+xiangId;
}
$(function(){
    var options = {
        url :prefix+"/infoTable?xiangId="+xiangId,
        exportUrl: exportUrl,
        modalName: "居民户籍信息",
        showSearch: false,
        showRefresh: false,
        showToggle: false,
        showColumns: false,
        columns:[
            [{
                field: 'townId',
                title: '编号',
                rowspan : 2,
                align: "center",
                valign: "middle"
            }, {
                field: 'townName',
                title: '乡镇',
                rowspan : 2,
                align: "center",
                valign: "middle"
            }, {
                field: 'accurateNum',
                title: titleValue('精准确村确户总户数'),
                rowspan : 2,
                align: "center",
                valign: "middle"
            }, {
                field: 'householdsNum',
                title: titleValue('常住人口户数'),
                rowspan : 2,
                align: "center",
                valign: "middle"
            }, {
                field: 'cleanCoalNum',
                title: titleValue('洁净煤取暖户数'),
                rowspan : 2,
                align: "center",
                valign: "middle"
            }, {
                field: 'notCleanCoalNum',
                title: titleValue('洁净煤未入户数'),
                rowspan : 2,
                align: "center",
                valign: "middle"
            }, {
                field: 'otherWarmNum',
                title: titleValue('采用其他方式取暖户数'),
                rowspan : 2,
                align: "center",
                valign: "middle"
            }, {
                field: 'notWarmNum',
                title: titleValue('冬季不取暖户数'),
                rowspan : 2,
                align: "center",
                valign: "middle"
            },{
                field: 'biomassWarmNum',
                title: titleValue('生物质取暖户数'),
                rowspan : 2,
                align: "center",
                valign: "middle"
            }, {
                field: '',
                title: '乡镇',
                align: "center",
                colspan : 2,
                valign: "middle"
            }, {
                field: '',
                title: '村',
                align: 'center',
                colspan : 2,
                valign: "middle"
            },{
                field: 'totalBuyNum',
                title: titleValue('总购洁净煤数(吨)'),
                rowspan : 2,
                align: "center",
                valign: "middle"
            }],[
                {
                    field: 'townBlNum',
                    title: '乡镇包联人数',
                    rowspan : 1,
                    align: "center",
                    valign: "middle"
                },
                {
                    field: 'townBlVillageNum',
                    title: '包联村数',
                    rowspan : 1,
                    align: "center",
                    valign: "middle"
                },
                {
                    field: 'villageBlNum',
                    title: titleValue('村级包联人数'),
                    rowspan : 1,
                    align: "center",
                    valign: "middle"
                }, {
                    field: 'villageBlHouseNum',
                    title: titleValue('包联户数'),
                    align: "center",
                    valign: "middle"
                }
            ]]
    };
    $.table.init(options);
});
</script>
</body>
</html>